package ex.com.jm.food.service.impl;

import java.util.List;

import ex.com.jm.food.dao.AdminCompanyTypeDao;
import ex.com.jm.food.entity.CompanyType;
import ex.com.jm.food.service.AdminCompanyTypeService;

public class AdminCompanyTypeServiceImpl implements AdminCompanyTypeService {


	private AdminCompanyTypeDao adminCompanyTypeDao;
	public AdminCompanyTypeDao getAdminCompanyTypeDao() {
		return adminCompanyTypeDao;
	}

	public void setAdminCompanyTypeDao(AdminCompanyTypeDao adminCompanyTypeDao) {
		this.adminCompanyTypeDao = adminCompanyTypeDao;
	}

	@Override
	public List<CompanyType> getCompanyTypes(int initPage, int pageRow,
			String name, Integer status, String order, String sort) {
		// TODO Auto-generated method stub
		return this.getAdminCompanyTypeDao().getCompanyTypes(initPage, pageRow, name, status, order, sort);
	}

	@Override
	public int getcomTypeCount(String name, Integer status) {
		// TODO Auto-generated method stub
		return this.getAdminCompanyTypeDao().getcomTypeCount(name, status);
	}

	@Override
	public Object saveComType(CompanyType companyType) {
		// TODO Auto-generated method stub
		return this.getAdminCompanyTypeDao().saveComType(companyType);
	}

	@Override
	public void updateComtype(CompanyType companyType) {
		// TODO Auto-generated method stub
     this.getAdminCompanyTypeDao().updateComtype(companyType);
	}

	@Override
	public CompanyType editCompanyType(Integer id) {
		// TODO Auto-generated method stub
		return this.getAdminCompanyTypeDao().editCompanyType(id);
	}

	@Override
	public boolean updateStatus(Integer status, Integer id) {
		// TODO Auto-generated method stub
		return this.getAdminCompanyTypeDao().updateStatus(status, id);
	}

	@Override
	public CompanyType checkName(String name) {
		// TODO Auto-generated method stub
		return this.getAdminCompanyTypeDao().checkName(name);
	}

}
